package com.github.boluo1230.wechat.entity;

import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import org.springframework.data.annotation.Id;
import org.springframework.data.mongodb.core.mapping.Document;
import org.springframework.format.annotation.DateTimeFormat;

import java.util.Date;
import java.util.List;

/**
 * @author Code Farmer
 * @date 2019/10/12 21:01
 */
@Document(collection = "mp_app")
@Data
public class MpApp {

    @Id
    private String appId;
    private String appSecret;
    private String name;
    private String tokenUrl;
    private String jsconfigUrl;
    private List<String> serviceUrl;
    private String signToken;
    private String logo;
    private String type;

    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date createDate;
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date updateDate;

}
